import QtQuick
import QtQuick3D

import "../gameToolKit"

//一个方形的Actor

Node{
    id:root

    //想要获取上下文以及被控制就需要在顶端节点设置这些属性
    property GameContextBase context
    property ControllerBase controller

    Model {
        position: Qt.vector3d(0, -100, 0)
        source: "#Cube"
        scale: Qt.vector3d(2, 0.2, 1)
        materials: [ DefaultMaterial {
                diffuseColor: "blue"
            }
        ]
    }

    Connections{
        target:controller

        function onGoUp(){
            root.position.y += 10
        }

    }

}
